package com.hu.pojo.dto.question;

import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotEmpty;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.List;

/**
 * 创建题目请求
 */
@Data
public class QuestionAddRequest implements Serializable {

    /**
     * 题目库 id
     */
    @NotEmpty
    private List<Long> questionBankId;

    /**
     * 标题
     */
    @NotBlank
    @Size(min = 1, max = 60)
    private String title;

    /**
     * 内容
     */
    @NotBlank
    @Size(min = 1, max = 1024)
    private String content;

    /**
     * 标签列表
     */
    @NotEmpty
    private List<String> tags;

    /**
     * 推荐答案
     */
    @NotBlank
    private String answer;

    private static final long serialVersionUID = 1L;
}